package com.ych.modules.base.dbEntity;

import com.baomidou.mybatisplus.annotations.TableField;
import com.baomidou.mybatisplus.annotations.TableId;
import com.baomidou.mybatisplus.annotations.TableName;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import java.math.BigDecimal;
import java.util.Date;
import java.util.List;

/**
 * Created with IntelliJ IDEA.
 * Author: Usopp.tsui
 * Date: 2021/3/15
 * Time: 15:57
 * Description:
 */
@Data
@TableName("t_raffle_ticket_jackpot")
@ApiModel(value = "TRaffleTicketJackpotEntity", description = "数据库-奖池表")
public class TRaffleTicketJackpotEntity extends AbstractPageEntity {
    @TableId(value = "jackpot_id")
    @ApiModelProperty(value = "主键", dataType = "String", notes = "主键")
    private String jackpotId;

    @TableField(value = "user_id")
    @ApiModelProperty(value = "创建用户id", dataType = "String", notes = "创建用户id")
    private String userId;

    @TableField(value = "amount")
    @ApiModelProperty(value = "奖池总金额", dataType = "BigDecimal", notes = "奖池总金额")
    private BigDecimal amount;

    @TableField(value = "lottery_time")
    @ApiModelProperty(value = "开奖时间", dataType = "Date", notes = "开奖时间")
    private Date lotteryTime;

    @TableField(value = "latest_purchase_time")
    @ApiModelProperty(value = "最后购买时间，过了这个时间不能再买了", dataType = "Date", notes = "最后购买时间，过了这个时间不能再买了")
    private Date latestPurchaseTime;

    @TableField(value = "create_time")
    @ApiModelProperty(value = "创建时间", dataType = "Date", notes = "创建时间")
    private Date createTime;

    @TableField(value = "issue_code")
    @ApiModelProperty(value = "旗号标号，第***期", dataType = "String", notes = "旗号标号，第***期")
    private String issueCode;

    @TableField(value = "lottery_number")
    @ApiModelProperty(value = "开奖号码", dataType = "String", notes = "开奖号码")
    private String lotteryNumber;

    @TableField(value = "jackpot_status_type")
    @ApiModelProperty(value = "奖池状态码值", dataType = "String", notes = "奖池状态码值")
    private String jackpotStatusType;

    @TableField(exist = false)
    @ApiModelProperty(value = "参与抽奖的奖券集合", dataType = "List<TUserRaffleTicketEntity>", notes = "参与抽奖的奖券集合")
    private List<TUserRaffleTicketEntity> raffleTicketList;

    @TableField(exist = false)
    @ApiModelProperty(value = "当前用户投注数量", dataType = "Integer", notes = "当前用户投注数量")
    private Integer currentUserBetNum;

    @TableField(exist = false)
    @ApiModelProperty(value = "上一期期号", dataType = "String", notes = "上一期期号")
    private String lastIssueCode;

    @TableField(exist = false)
    @ApiModelProperty(value = "上一期开奖号码", dataType = "String", notes = "上一期开奖号码")
    private String lastLotteryNumber;
}
